Repository navigation
Conversation
2fbc5f4 to
b545f9d
Compare
|
@richsalz ... would you have any suggestions on this ... looks like when using the secure heap allocator the DBRG is holding on to some memory causing our asan test to fail... https://github.com/nodejs/node/pull/36976/checks?check_run_id=1717756455 |
|
Do you load openssl dynamically? If so, do you explicilty unload it? I can ping folks for details on how to cleanup, but first those questions. |
Here's the init logic... https://github.com/nodejs/node/blob/master/src/crypto/crypto_util.cc#L102-L163 There is no explicit cleanup unless I've missed something (/cc @addaleax @joyeecheung) |
|
Ping @paulidale and @mattcaswell; maybe they can help with freeing up secure heap? |
|
Nothing jumps out at me as forcing a provider or library context reference count increment. If @mattcaswell doesn't have a look, I can once my vacation finishes. |
|
@paulidale ... Is there a simple way of checking the current ref count? |
|
Sadly, no. We should have a reference count trace capability given the time these issues take to track down. |
|
Which OpenSSL version is this? |
|
It's version |
|
You shouldn't need to call I tried to create a standalone C reproducer of this leak, but I was unsuccessful. If anyone can help me with that then I can investigate further. Otherwise it might need @paulidale to return from vacation. |
|
Thanks @mattcaswell and @paulidale ... I'll keep digging but anything does happen to spring to mind, please do let me know. My plan currently is to inject some tracing logic into openssl and see if I can spot anything. At the very least I want to check whether the implicit call to |
8f808f2 to
9699aad
Compare
|
Ok, well... I've been able to at least verify that the leak (a) is definitely being caused by enabling the secure heap and (b) the implicit cleanup is happening with secure heap use reporting 0 at cleanup... making it even less clear exactly why we're getting the failure report here. Still investigating. |
|
At this point I've really no idea why the asan failure is happening. @addaleax ... you might be able to have some better luck with it but as far as I can see, all the memory is being cleaned up correctly. |
See if this fixes the asan error in test-crypto-secure-heap
Do not land this yet... as it's not ready to go, despite the sign offs